package com.test34_类加载器.net.client;

import com.test34_类加载器.net.util.NetClassLoader;

import java.lang.reflect.Method;

public class MessageClient {

    public static void main(String[] args) throws Exception {
        NetClassLoader netClassLoader = new NetClassLoader();
        Class<?> clazz = netClassLoader.loadData("com.test26_类加载器.Message");
        Object messageObject = clazz.getDeclaredConstructor().newInstance();
        Method method = clazz.getMethod("echo", String.class);
        System.out.println(method.invoke(messageObject, "沐言优拓：www.yootk.com"));
    }
}
